{% include 'includes/nav.html' %}

<h1>{{current_date}}</h1>

{% 	if template_name %}
{%	include template_name %}
{%	else %}
<p>not input template name</p>
{%	endif	%}


{% if error %}
<p style="color: red;">{{error}}</p>
{% endif %}
<form action="/search/" method="get">
    <input type="text" name="q" value="{{user.name}}">
    <input type="submit" value="Search">
</form>

{% for user in users %}  
<h3 {% if forloop.first %}style="color:red;"{% endif %}
	{% if forloop.last %}style="color:bule;"{% endif %}>
	{{ forloop.counter }}: {{ user.name }} - {{user.name.upper}}
	{% ifequal user.name 'li' %}  
	    <span> - is equal </span>  
	{% else %}
	    <span> - is equal else</span>  
	{% endifequal %}  
</h3>  
<ul>  
{% for hobby in user.hobbies reversed %}  
<li>#{{ forloop.parentloop.counter }} - {{ forloop.counter }}:  {{ hobby }}</li>  
{% endfor %}  
</ul>
{% endfor %}  



<script>
var books = {{books|escape}}
var users = {{users}}
var cur_user = {{cur_user}}
</script>